package puzzle.slilin2.solver;

import java.util.ArrayList;
import java.util.List;

import puzzle.common.point.Pnt;
import puzzle.slilin2.data.LineCellState;
import puzzle.slilin2.data.SlilinBoard;

class LineCount {
	private List<LineCellState> m_unfixedCellStates = new ArrayList<LineCellState>();
	private int m_existsCount;
	private int m_forbiddenCount;
	
	public LineCount(SlilinBoard b, Pnt... ps) {
		for (Pnt p : ps) {
			LineCellState s = b.getLineCellState(p);
			if (s.isForbidden()) {
				m_forbiddenCount++;
			} else if (s.exists()) {
				m_existsCount++;
			} else {
				m_unfixedCellStates.add(s);
			}
		}
	}

	public List<LineCellState> getUnfixedCellStates() {
		return m_unfixedCellStates;
	}

	public int getExistsCount() {
		return m_existsCount;
	}

	public int getForbiddenCount() {
		return m_forbiddenCount;
	}
	

}
